home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-04 / insitx10.zip / INSIGHTX.TXT < prev    next >
Text File  |  1992-10-24  |  81KB  |  1,514 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.                             Insight for xBase (tm)
  11.  
  12.                                  Version 2.00
  13.  
  14.                                  User's Manual
  15.  
  16.  
  17.  
  18.  
  19.                                Shareware Version
  20.  
  21.  
  22.  
  23.                    (C) Copyright 1992 - All Rights Reserved
  24.  
  25.  
  26.                               McKelvy Enterprises
  27.                               3149 Bradford Place
  28.                              Birmingham, AL  35242
  29.  
  30.                            CompuServe ID: 71477,3513
  31.  
  32.  
  33.       LICENSE
  34.  
  35.       The Insight for xBase software and manual are copyrighted, all rights are
  36.       reserved.  You have purchased a license to use this software on one
  37.       machine at a time.  You are authorized to make copies of Insight for xBase for
  38.       the sole purpose of backing up your software and protecting your
  39.       investment from loss.  
  40.  
  41.       Note:  This copy of Insight for xBase is being distributed as Shareware. This
  42.       means that you may copy the disk just as you received it and you may give
  43.       it to others for their trial use. You are also permitted and encouraged to
  44.       upload this version to electronic bulletin board services. You may not, 
  45.       however, resell or collect any fee for the distribution of Insight for xBase
  46.       without the permission of McKelvy Enterprises. (This does not include the
  47.       normal fees for using bulletin boards.) If you continue to use Insight for
  48.       xBase after your trial use, you must pay the purchase price as detailed
  49.       below.
  50.  
  51.       WARRANTY
  52.  
  53.       This software will perform as described herein only if properly applied. 
  54.       Our liability to you is limited to replacing the software (FOR REGISTERED
  55.       USERS ONLY).  We have no liability to you for any damage or loss (whether
  56.       special, incidental, or consequential) caused by this software, either
  57.       directly or indirectly.
  58.  
  59.       You agree to the terms of this license by your decision to use this
  60.       software.
  61.  
  62.       SHAREWARE
  63.  
  64.       Insight for xBase is copyrighted. It is not a public domain program. It is
  65.       being distributed as Shareware, which means that unmodified copies of the
  66.       software and documentation may be freely copied and shared. We ask in
  67.       return that should you find Insight for xBase to be a useful program, you
  68.       become a registered user by sending $30.00 to:
  69.  
  70.                        McKelvy Enterprises
  71.                        3149 Bradford Place
  72.                       Birmingham, AL  35242
  73.  
  74.       The file ORDER.FRM on the disk can be printed and used as an order form.
  75.  
  76.       By becoming a registered user, you get:
  77.  
  78.         o   The latest version of the software without the introductory
  79.             Shareware screen.
  80.  
  81.  
  82.         o   Free telephone (your Quarter) support for help with problems in
  83.             running Insight for xBase.  In addition, you may make suggestions on how
  84.             to improve the program.  You may also get support by writing to us
  85.             at the above address (this is the preferred method).
  86.  
  87.         o   A bound user's manual showing sample code (some with intentional
  88.             errors) and the output produced by Insight for xBase.
  89.  
  90.         o   Information on new versions of Insight for xBase as soon as they are
  91.             available.
  92.  
  93.         o   The source code for Insight for xBase (available to registered users for
  94.             an additional fee).
  95.  
  96.       The shareware philosophy is to pay smaller amounts for well-crafted and
  97.       useful software from developers who cannot spend the millions of dollars
  98.       on packaging and marketing necessary to compete with the large software
  99.       development companies. You benefit by being able to try (for free) a wider
  100.       variety of software products to find the ones that best suit your
  101.       particular purpose.  The shareware developer benefits from being able to
  102.       distribute his work to a wider audience than would be possible through
  103.       normal channels.  In order for Shareware to grow and prosper (with the
  104.       development of more and better products), it is your responsibility to
  105.       distribute your shareware programs to others and to become a registered
  106.       user of those products you like and use.
  107.  
  108.  
  109.                                1.0  Introduction
  110.  
  111.  
  112. Insight for xBase is a program designed to help with the documentation and debugging
  113. of xBase programs.  The program is specifically designed for use with programs
  114. developed with FoxBase+ (tm), FoxPro (tm), dBase III+ (tm), or dBase IV (tm).
  115.  
  116. The purpose of Insight for xBase is to provide the system developer with a formatted
  117. source listing and variable cross-reference for xBase programs.  The formatted
  118. listing will show DO..LOOP and WHILE..WEND ranges, IF..THEN..ELSE..END IF true
  119. and false ranges, and the range of each CASE statement in a SELECT CASE group. 
  120. The listing will also display error messages if program loops are improperly
  121. nested.  The variable cross-reference will show the name of each variable or
  122. xBase keyword in a subroutine (or the main module) and the line numbers where the
  123. variable is referenced.  Additionally, a global variable cross-reference is also
  124. available.  This shows the names of the subroutines which use each variable or
  125. xBase keyword.  The program documentation along with its table of contents may
  126. be written either to a file or to the printer.
  127.  
  128. In addition to the listing described above, Insight for xBase is also capable of
  129. simultaneously producing an indented source listing.  This is simply a copy of
  130. the input program with all of the DO..LOOP, WHILE..WEND, IF..THEN..ELSE..END IF,
  131. and SELECT CASE structures indented for easier reading.  The indented source
  132. listing is a program file and can be used like any other program file you might
  133. create.
  134.  
  135.  
  136.  
  137.                               System Requirements
  138.  
  139. Insight for xBase will work on any IBM-compatible personal computer running MS-DOS
  140. or PC-DOS 3.30 (or higher) with at least 512K of available memory.  The program
  141. may be run from a floppy drive, but a hard drive is recommended, and may be
  142. essential, for the variable cross-reference due to the size of temporary files.
  143.  
  144. The program speed is, of course, dependent on processor speed, but does not seem
  145. to be dependent on processor type (i.e., 286 vs 386).  A program of about 2000
  146. lines can be processed in less than a minute without the cross-reference, and in
  147. about two minutes with the cross-reference running on a 20MHz 386 machine.
  148.  
  149.  
  150.  
  151.                           2.0  Running Insight for xBase
  152.  
  153.  
  154. You can run Insight for xBase in either a menu mode or a command line mode.  In
  155. either case, you start the program by typing INSIGHTX, followed by any command line
  156. options, at the DOS prompt and pressing <Enter>.  This assumes either that you
  157. are in the directory which contains Insight for xBase or that you have that directory
  158. specified in your PATH statement.  If this is not the case, you will need to
  159. specify the full path to the Insight for xBase executable file (i.e.,
  160. C:\INSIGHTX\INSIGHTX).
  161.  
  162. As stated, a number of the programs options can be specified from the command
  163. line using command line options.  Command line options are designated by a slash
  164. (/), followed by a letter, followed by the option data.  The command line option
  165. of /G causes the program to bypass the menus, run the analysis of the specified
  166. program, and return to the DOS prompt.  If the /G option is not specified, then
  167. any options entered will be used as the initial values in the menus.
  168.  
  169. In the following descriptions, each section will describe a menu option, and the
  170. equivalent command line option (if any) will be specified.  In addition, the
  171. command line options will be summarized in Appendix A.  The four main menu
  172. options (File, Options, Run, and Help) are described in Sections 2.1 through 2.4
  173. respectively.  In each menu section, the text will be referred to input
  174. structures such as an input box, list box, check box, and option box.  These
  175. input structures and how they are used will be described in Appendix B.
  176.  
  177. In either mode of operation, as Insight for xBase is running, information about the
  178. program being analyzed and the format of the output will be displayed on the
  179. screen in an information box as shown below:
  180.  
  181.  +===========================================================================+
  182.  |                                                                           |
  183.  | Input File: C:\XBASE\SAMPLE.PRG                                           |
  184.  | Output to: C:\XBASE\SAMPLE.LST                                            |
  185.  | MAK File?: No  Process INCLUDE Files?: No                                 |
  186.  | Create formatted source files?: Yes     Extension: SRC                    |
  187.  |                                                                           |
  188.  |  Local Concordance:   Variable: Yes    Keyword:No                         |
  189.  | Global Concordance:   Variable: Yes    Keyword:No                         |
  190.  |                                                                           |
  191.  | Line Length: 115      Lines per Page: 60                                  |
  192.  | Number of Characters to Indent: 3                                         |
  193.  | Page Header:                                                              |
  194.  | Date: \D     File: \F                   Page: \P                          |
  195.  | Version of xBase: FoxPro                                                  |
  196.  |                                                                           |
  197.  |                                                                           |
  198.  |                                                                           |
  199.  +===========================================================================+
  200.  
  201.  
  202.                                 2.1  File Menu
  203.  
  204. The File Menu (Figure 2.1) allows the user to 1) specify the input file, 2)
  205. identify the input file as a list of files to be processed, 3) specify the output
  206. device, 4) indicate that indented source files are to be created, 5) read a
  207. configuration file, 6) save a configuration file, or 7) exit the program.  The
  208. File Menu is accessed by pressing <Alt>-F (holding down the Alt key while
  209. pressing F) or by placing the mouse cursor over the word file and clicking the
  210. left button.  Once the menu is displayed, a selection may be made by pressing the
  211. highlighted letter, using the cursor keys to highlight the selection and pressing
  212. <Enter>, or placing the mouse cursor over the selection and clicking the left
  213. mouse button.  In Figure 2.1, the highlighted letter for each selection is shown
  214. in boldface type.
  215.                                                                         
  216. +========================= Figure 2.1  File Menu ======================+
  217. |                                                                      |
  218. |   File   Options   Run   Help                                        |
  219. | +--------------------+                                               |
  220. | | Input File         |                                               |
  221. | | MAK File           |                                               |
  222. | +--------------------+                                               |
  223. | | Output             |                                               |
  224. | | Indented Source    |                                               |
  225. | +--------------------+                                               |
  226. | | Read Configuration |                                               |
  227. | | Save Configuration |                                               |
  228. | +--------------------+                                               |
  229. | | Exit               |                                               |
  230. | +--------------------+                                               |
  231. |                                                                      |
  232. +======================================================================+
  233.  
  234.  
  235. 2.1.1  Input File
  236.  
  237. When the Input File option is selected from the menu, the user is prompted with
  238. an input box (shown in Figure 2.2) in which to enter a file specification.  The
  239. user may enter a complete file name (optionally including a file path), or may
  240. enter a file name containing wildcard characters (i.e., asterisk - *, or question
  241. mark - ?).  If a complete file name is entered, the program checks for the file's
  242. existence and notifies the user if the file is not found.  If wildcards are used,
  243. the user is presented with a list box containing file names (example in Figure
  244. 2.3) which match the file specification and the user may then choose a file from
  245. the list.  If the user selects <Cancel> from the list box, then a message is
  246. displayed reminding the user that no file was selected.
  247.  
  248. If the user does not specify a path in the input file description, then the
  249. default path for source files is used.  This path is specified in the File Paths
  250. menu option described in Section 2.2.3.  Once the input file has been specified,
  251. the name (along with the full path) is shown in the program information box.
  252.  
  253.  
  254. Command Line Option: /Finput file
  255.  
  256. When specifying the input file from the command line, the input file must be
  257. specified, must immediately follow the /F, and Wildcards may not be used.  Also,
  258. the path for the files is assumed to be the current directory if no path is
  259. specified.
  260.  
  261. +============== Figure 2.2  File Specification Input Box  =================+
  262. |                                                                          |
  263. |    +----------------------------------------------------------+          |
  264. |    |                                                          |          |
  265. |    |         Enter a file specification:                      |          |
  266. |    |      +-----------------------------------+               |          |
  267. |    |      |  *.*                              |               |          |
  268. |    |      +-----------------------------------+               |          |
  269. |    |                                                          |          |
  270. |    |                 < OK >                                   |          |
  271. |    |                                                          |          |
  272. |    |                                                          |          |
  273. |    +----------------------------------------------------------+          |
  274. |                                                                          |
  275. +==========================================================================+
  276.                                  
  277.                                  
  278. +================  Figure 2.3  File List Box  ==========================+
  279. |            +---------------------------+                              |
  280. |            |  +----------------+       |                              |
  281. |            |  |  SAMPLE1.BAS   |       |                              |
  282. |            |  |  SAMPLE1.EXE   ^       |                              |
  283. |            |  |  SAMPLE1.LST   *       |                              |
  284. |            |  |  SAMPLE1.OBJ   #       |                              |
  285. |            |  |  SAMPLE2.BAS   #       |                              |
  286. |            |  |  SAMPLE2.EXE   #       |                              |
  287. |            |  |  SAMPLE2.LST   #       |                              |
  288. |            |  |  SAMPLE2.OBJ   #       |                              |
  289. |            |  |  SAMPLE3.BAS   #       |                              |
  290. |            |  |  SAMPLE3.EXE   #       |                              |
  291. |            |  |  SAMPLE3.LST   #       |                              |
  292. |            |  |  SAMPLE3.OBJ   v       |                              |
  293. |            |  |  TEST.BAT      |       |                              |
  294. |            |  +----------------+       |                              |
  295. |            |                           |                              |
  296. |            |    < OK >     < Cancel >  |                              |
  297. |            |                           |                              |
  298. |            +---------------------------+                              |
  299. |                                                                       |
  300. +=======================================================================+
  301.  
  302.  
  303.  
  304.  
  305.                                 2.1.2  MAK File
  306.  
  307. This option specifies whether or not the file entered as the input file is in
  308. fact a list of files to be processed.  The list of files must be in ASCII format
  309. with one file per line.  On each line, the file name must be the first entry on
  310. the line and must be separated from any other information on the line by a space. 
  311. The status of the option is displayed in the information box, and is shown on the
  312. menu by the presence (if activated) or absence (not activated) of a » mark.
  313.  
  314. Command Line Option: /M
  315.  
  316.  
  317.  
  318. 2.1.3  Output
  319.  
  320. When the Output option is selected from the menu, an option box (Figure 2.4) is
  321. presented which allows the user to select None (for no documentation output),
  322. File (for output to a file), or Printer (for output to a print device).
  323.  
  324.       If None is selected, no documentation output is produced.  This option
  325.       would be selected if the user only wants to produce an indented source
  326.       file as described in Section 2.1.4.
  327.  
  328.       If File is selected, the user is prompted with an input box in which to
  329.       enter a file specification.  The user may enter a complete file name
  330.       (optionally including a file path), or may enter a file name containing
  331.       wildcard characters.  If a complete file name is entered, the program
  332.       checks for the file's existence and notifies the user if the file is
  333.       found, asking if it should be overwritten.  If wildcards are used, the
  334.       user is presented with a list of files which match the file specification
  335.       and the user may then choose a file from the list.  If the user does not
  336.       specify a path in the output file description, the default path for source
  337.       files is used.  This path is specified in the File Paths menu option
  338.       described in Section 2.2.3.  The input box and list box for the output
  339.       file are the same as those for the input files (Figures 2.2 and 2.3).
  340.  
  341.       If Printer is selected, the user is presented with a list box (Figure 2.5)
  342.       containing the print devices LPT1 - LPT4 and COM1 - COM4, and a selection
  343.       of the print device is made from the list.  Once the output device has
  344.       been specified, the information is displayed in the information box.
  345.  
  346. Command Line Option: /Ooutput
  347.  
  348. When specifying the output device from the command line, the user should either
  349. enter a complete file name (including the file path if necessary) or the name of
  350. a print device (i.e., LPT1 or COM1).  As with the input file, wildcards may not
  351. be entered from the command line.  If no output device is specified on the
  352. command line, then "None" is assumed.
  353.  
  354.  
  355. +======================  Figure 2.4  Output =============================+
  356. |                                                                        |
  357. |   +=================== Output Device Selection ==================+     |
  358. |   |                                                              |     |
  359. |   |                                                              |     |
  360. |   |                                                              |     |
  361. |   |         Output Devices for Documentation File                |     |
  362. |   |     (*) None    ( ) File       ( ) Printer                   |     |
  363. |   |           Output to:                                         |     |
  364. |   |                                                              |     |
  365. |   |                                                              |     |
  366. |   |                             < Cancel >                       |     |
  367. |   |                                                              |     |
  368. |   +==============================================================+     |
  369. |                                                                        |
  370. +========================================================================+
  371.  
  372.                                  
  373. +================  Figure 2.5  Printer List Box  =======================+
  374. |            +---------------------------+                              |
  375. |            |  +----------------+       |                              |
  376. |            |  |  LPT1          |       |                              |
  377. |            |  |  LPT2          ^       |                              |
  378. |            |  |  LPT3          *       |                              |
  379. |            |  |  LPT4          #       |                              |
  380. |            |  |  COM1          #       |                              |
  381. |            |  |  COM2          #       |                              |
  382. |            |  |  COM3          v       |                              |
  383. |            |  |  COM4          |       |                              |
  384. |            |  +----------------+       |                              |
  385. |            |                           |                              |
  386. |            |    < OK >     < Cancel >  |                              |
  387. |            |                           |                              |
  388. |            +---------------------------+                              |
  389. |                                                                       |
  390. +=======================================================================+
  391.  
  392.  
  393.  
  394.  
  395.                         2.1.4  Indented Source Listing
  396.  
  397. This option allows the user to generate indented source files.  These files are
  398. the same as the input program files except that command structures (such as DO
  399. loop, IF statements, CASE structures, etc.) are indented by a specified number
  400. of spaces.  This makes the source code itself easier to read, but does not affect
  401. the performance of the program.  It can still be edited and compiled like any
  402. other program file.  When the option is selected, an option box is presented
  403. asking if source files are to be created.  The user selects either the "Yes" or
  404. "No" button in the box.  The extension for the source file is specified in the
  405. File Paths menu option described in Section 2.2.3.  The default file extension
  406. is "SRC".
  407.  
  408. Command Line Option: /Sext
  409.  
  410. When specifying from the command line that source files are to be created, the
  411. file extension for the files must be specified.
  412.  
  413.  
  414.  
  415.                         2.1.5  Read Configuration File
  416.  
  417. When this option is selected, information about the analysis to be performed and
  418. the layout of the documentation is read in from a file.  The information includes
  419. whether local and/or global concordances (for variables or keywords) should be
  420. generated, the number of spaces to indent structures, the length of the output
  421. line, the number of lines per page, the page header, and the default language to
  422. use for keyword lookup.  The configuration file used in the menu options is
  423. always INSIGHTX.CFG and is found in the path designated in the File Paths menu
  424. option (Section 2.2.3).
  425.  
  426. Command Line Option: /Cfilename
  427.  
  428. When specifying the configuration file from the command line, the configuration
  429. file may have any file name.  It is recommended that the configuration file be
  430. placed prior to other format options on the command line, as the information in
  431. the file will override any format information already entered.
  432.  
  433. A sample configuration file and a description of how to create a file can be
  434. found in Appendix C.
  435.  
  436.  
  437.  
  438.                         2.1.6  Save Configuration File
  439.  
  440. When this option is selected, information about the analysis to be performed and
  441. the layout of the documentation is saved to a file.  The information includes
  442. whether local and/or global concordances should be generated, the number of
  443. spaces to indent structure, the length of the output line, the number of lines
  444. per page, the page header, and the default language to use for keyword lookup. 
  445. The configuration file name used is always INSIGHTX.CFG, and the file is output to
  446. the path designated in the File Paths menu option (Section 2.2.3).
  447.  
  448.  
  449.  
  450.  
  451.                                   2.1.7  Exit
  452.  
  453. Choosing this option terminates the program and returns the user to the DOS
  454. prompt.
  455.                                2.2  Options Menu
  456.  
  457. The Options Menu (Figure 2.6) allows the user to specify the output page format,
  458. the analysis options, and the file paths for various files used by Insight for xBase.
  459. The Options Menu is accessed by pressing <Alt>-O (holding down the Alt key while
  460. pressing O) or by placing the mouse cursor over the word Options and clicking the
  461. left button.  Once the menu is displayed, a selection may be made by pressing the
  462. highlighted letter, using the cursor keys to highlight the selection and pressing
  463. <Enter>, or placing the mouse cursor over the selection and clicking the left
  464. mouse button.  In Figure 2.6, the highlighted letter for each selection is shown
  465. in boldface type.
  466.                                                                         
  467. +======================= Figure 2.6  Options Menu =====================+
  468. |                                                                      |
  469. |   File   Options   Run   Help                                        |
  470. |        +--------------------+                                        |
  471. |        | Page Layout        |                                        |
  472. |        | Processing Options |                                        |
  473. |        | File Paths         |                                        |
  474. |        +--------------------+                                        |
  475. |                                                                      |
  476. +======================================================================+
  477.  
  478.  
  479.  
  480.                               2.2.1  Page Layout
  481.  
  482. The Page Layout option allows the user to enter format information such as the
  483. number of spaces to indent structures, the number of characters per line, the
  484. number of lines per page, and the header to be printed at the top of each page. 
  485. When the Page Layout option is selected, the user is presented with the input box
  486. shown in Figure 2.7.  The shaded regions indicate edit fields where the user
  487. actually enters the information.  After filling out the information, the user may
  488. select <Accept> to use the entered data, or <Cancel> to return the format
  489. settings to their previous values.
  490.  
  491.  
  492. +=================  Figure 2.7  Page Layout Screen =======================+
  493. |                                                                         |
  494. |  +=================== Page Layout Options ==========================+   |
  495. |  |                                                                  |   |
  496. |  |   Number of Spaces to Indent:     4                              |   |
  497. |  |                                                                  |   |
  498. |  |   Number of Characters Per Line:  132                            |   |
  499. |  |                                                                  |   |
  500. |  |   Number of Lines Per Page:       55                             |   |
  501. |  |                                                                  |   |
  502. |  |   Page Header String:                                            |   |
  503. |  |   Date: \D   Time: \T   Filename: \N   Subroutine: \S   Page     |   |
  504. |  |                                                                  |   |
  505. |  |   < Accept >                                    < Cancel >       |   |
  506. |  |                                                                  |   |
  507. |  +==================================================================+   |
  508. +=========================================================================+
  509.  
  510.  
  511.  
  512.                            2.2.1.1  Spaces to Indent
  513.  
  514. This option specifies the number of spaces to indent each "nest" of DO loops,
  515. FOR..NEXT loops, etc.  This value controls the appearance of the formatted
  516. output.  Each statement within the range of a loop is shown with a loop
  517. descriptive character and the number of spaces requested by the user in front of
  518. it (as shown in the example below).  For indented source output files the effect
  519. is similar, but there are no line numbers or loop descriptive characters present.
  520.  
  521.       Program Segment:
  522.  
  523.       DO WHILE condition
  524.       statement 1
  525.       statement 2
  526.       statement 3
  527.       ENDDO
  528.  
  529.       Formatted Listing (with 4 spaces selected):
  530.  
  531.       1     DO WHILE condition
  532.       2     L    statement 1
  533.       3     L    statement 2
  534.       4     L    statement 3
  535.       5     ENDDO
  536.  
  537. In this example, the numbers to the far left are line numbers, and the "L" is the
  538. DO loop descriptive character.
  539.  
  540.  
  541.       Indented Source File (with 4 spaces selected):
  542.  
  543.       DO WHILE condition
  544.           statement 1
  545.           statement 2
  546.           statement 3
  547.       ENDDO
  548.  
  549. The user can request any number of spaces (up to 10) for the indent function, but
  550. recommended values are from 1 to 5.
  551.  
  552. Command Line Option: /Nx
  553.  
  554. When entered from the command line, the user enters the number of space to indent
  555. (i.e., /N4).
  556.  
  557.  
  558.  
  559.                          2.2.1.2  Characters Per Line
  560.  
  561. This option specifies how many characters will be printed before Insight for xBase
  562. breaks the program statement into two or more output lines.  The length specified
  563. will be the number of characters on a line, including the line number, any
  564. indentations (see Section 2.2.1.1), and the program statement.  The user may
  565. input a value of 0, which will tell the program not to split the lines, or any
  566. integer value greater than 50.  The actual line length to be used will depend on
  567. the paper width and print font to be used to print the output file.  A value of
  568. 132 and a compressed font (17 cpi) for printing works well for most programs. 
  569. For indented source output, lines are never split and this value is ignored.
  570.  
  571. Command Line Option: /Lxxx
  572.  
  573. When entered from the command line, the user enters the number of characters per
  574. line (i.e., /L132).
  575.  
  576.  
  577.  
  578.                             2.2.1.3  Lines Per Page
  579.  
  580. This option specifies the number of lines to be printed per page when the file
  581. is sent to a printer.  The program will issue a form feed character each time the
  582. "lines per page" counter exceeds the input value.  The program will also issue
  583. a form feed each time a new subroutine or function is encountered.  The lines
  584. printed on a page also includes the three-line report header which is printed at
  585. the top of each page.  While most printers can print up to sixty-six lines per
  586. page (some can print more), a value of 55 lines per page seems to work well for
  587. most printer setups.
  588.  
  589. Command Line Option:  /Pxx
  590.  
  591. From the command line, the user enters the number of lines per page (i.e., /P55).
  592.  
  593.  
  594.  
  595.                              2.2.1.4  Page Header
  596.  
  597. This option specifies the page header (single line) to be printed at the top of
  598. each page of the output report.  The page header can be as long as the line
  599. length specified in Section 2.2.1.2, and can contain any descriptive text the
  600. user wants to include.  In addition, the user may include backslash (\) operators
  601. in the text to have program-dependent data printed in the header.  These
  602. operators take the form of \A, where "A" is one of the following five
  603. descriptors:
  604.  
  605.       D -   The date that the report was run.  This is pulled from the system
  606.             date function.
  607.       T -   The time that the run started.  This is pulled from the system time
  608.             function.
  609.       N -   The name of the file being processed.  This can be useful when
  610.             processing a MAK file, as the program will use the names of the
  611.             files being analyzed to show which routines are part of which file.
  612.       S -   The current subroutine being processed.  This is taken from the SUB
  613.             or FUNCTION statement at the beginning of each routine.  For the
  614.             first routine (which is unnamed), the default name is the name of
  615.             program file without the path or file extension.
  616.       P -   The current page number.
  617.  
  618. When entering this data in the edit field, up to 132 characters will be accepted
  619. as input, but only 60 characters will be displayed at a time.
  620.  
  621. Command Line Option: /Hpage_header_information
  622.  
  623. When entering the page header data from the command line, an underscore (_) must
  624. be used to indicate each space in the header string.  This is required since the
  625. module which processes the command line options looks for spaces to separate the
  626. different options.  Each underscore will be converted to a space prior to
  627. printing the page header.
  628.  
  629.  
  630.  
  631.                            2.2.2  Processing Options
  632.  
  633. The Processing Options choice allows the user to make choices about the type of
  634. concordances (local or global cross-references of variables and/or keywords) to
  635. have printed, the language used by the program being analyzed (this is to
  636. determine the keyword set to be used), and whether or not to process INCLUDE
  637. files.  The user is presented with an input panel (Figure 2.8) which contains a
  638. series of check boxes, a set of radio buttons for choosing the language, and
  639. command buttons for processing the input.  After making selections of processing
  640. options, the user may select <Accept> to use the selected choices, or <Cancel>
  641. to return the processing options to their previous settings.
  642.  
  643.  
  644. +=================  Figure 2.8  Processing Options Screen  ===============+
  645. |                                                                         |
  646. | +===================== File Processing Options =====================+   |
  647. | |                                                                   |   |
  648. | |  Local Concordances:            Global Concordances:              |   |
  649. | |  [X] Variables                  [X] Variables                     |   |
  650. | |  [ ] Keywords                   [ ] Keywords                      |   |
  651. | |                                                                   |   |
  652. | |                                                                   |   |
  653. | |                                                                   |   |
  654. | |      Language to use for Keywords                                 |   |
  655. | |  (*) None  ( ) FoxPro  ( ) dBase IV  ( ) FoxBase+  ( ) dBase III  |   |
  656. | |                                                                   |   |
  657. | |  < Accept >                                  < Cancel >           |   |
  658. | |                                                                   |   |
  659. | +===================================================================+   |
  660. +=========================================================================+
  661.  
  662.  
  663.                         2.2.2.1  Variable Concordances
  664.  
  665. A variable concordance is a listing of the variables used in a subroutine or a
  666. program along with information about where they are used.  A local variable
  667. concordance may be printed at the end of each subroutine, and lists the variables
  668. used in that subroutine and the line numbers on which they appear.  This is often
  669. useful in discovering typographical errors, or in determining where the value of
  670. a variable has been redefined.  To select local variable concordance from the
  671. input panel, mark the Variables check box under Local Concordances.  A global
  672. variable concordance may be printed at the end of the program, and lists all the
  673. variables used in the program and the subroutines in which they appear.  This is
  674. useful in helping to determine what effect (if any) changing the value of a
  675. variable in one subroutine will have on another subroutine.  To select global
  676. variable concordance from the input panel, mark the Variables check box under
  677. Global Concordances.
  678.  
  679. Command Line Option: /Va
  680.  
  681. From the command line, the letter following the /V determines the type of
  682. variable concordance to be printed.  For a local concordance, enter L; for a
  683. global concordance, enter G; or to have both local and global concordances
  684. printed, enter B.
  685.  
  686.  
  687.  
  688.                          2.2.2.2  Keyword Concordances
  689.  
  690. A keyword concordance is a listing of the keywords used in a subroutine or a
  691. program along with information about where they are used.  A keyword concordance
  692. is most useful in determining the effect of a version change of a language when
  693. the operation or syntax of a command might have changed.  It is also very useful
  694. when porting code from one flavor of xBase to another (i.e., FoxPro to dBase IV),
  695. or to another language, to determine what commands or functions are
  696.  
  697. required by a program that might not be present in the new language.  A local
  698. keyword concordance may be printed at the end of each subroutine, and lists the
  699. keywords used in that subroutine and the line numbers on which they appear.  To
  700. select local keyword concordance from the input panel, mark the Keywords check
  701. box under Local Concordances.  A global keyword concordance may be printed at the
  702. end of the program, and lists all the keywords used in the program and the
  703. subroutines in which they appear.  To select global keyword concordance from the
  704. input panel, mark the Keywords check box under Global Concordances.
  705.  
  706. Command Line Option: /Ka
  707.  
  708. From the command line, the letter following the /K determines the type of keyword
  709. concordance to be printed.  For a local concordance, enter L; for a global
  710. concordance, enter G; or to have both local and global concordances printed,
  711. enter B.
  712.  
  713.  
  714.  
  715.                          2.2.2.4  Programming Language
  716.  
  717. The purpose of selecting the programming language used is to determine the
  718. keyword set to be used in the processing of the variable and keyword
  719. concordances.  If no language is selected, Insight for xBase treats both variables
  720. and keywords the same, and processes them as variables in the concordances.  Also
  721. no keyword concordance is possible.  To select the language from the input
  722. box, mark the space in front of the appropriate language.
  723.  
  724. Command Line Option: /Bn
  725.  
  726. To select the programming language from the command line, the number following
  727. the /B option is defined as follows:  1 for FoxPro, 2 for dBase IV, 3 for
  728. FoxBase+, and 4 for dBase III+.
  729.  
  730. NOTE:  If you are using Insight for xBase with a language other than one of the three
  731. that are specifically supported, a custom version of the code tailored for that
  732. language can be provided for you (for a small fee) if you will provide us with
  733. the keyword list.
  734.  
  735.  
  736.  
  737.                         2.2.3  File Path Specification
  738.  
  739. The File Path option allows the user to enter path information for files used by
  740. Insight for xBase.  These are the configuration files, keyword files, help files, and
  741. source program files.  The default value for the path for configuration, keyword,
  742. and help files is the subdirectory where the Insight for xBase executable file is
  743. located.  The default for the source program files is the current directory.  The
  744. user may also enter the file extension to be used for indented source output
  745. files.  The default extension is SRC.  When the File Path option is selected, the
  746. user is presented with the input box shown in Figure 2.9.  The shaded regions
  747. indicate edit fields where the user actually enters the information.  After
  748. filling out the information, the user may select <Accept> to use the entered
  749. data, or <Cancel> to return the path settings to their previous values.
  750.  
  751.  
  752. +===================  Figure 2.9  File Path Input Screen  ==================+
  753. |                                                                           |
  754. | +========================== Path Definitions ==========================+  |
  755. | |                                                                      |  |
  756. | |    Path for Configuration File:                                      |  |
  757. | |    C:\INSIGHTX\                                                      |  |
  758. | |                                                                      |  |
  759. | |    Path for Keyword Files:                                           |  |
  760. | |    C:\INSIGHTX\                                                      |  |
  761. | |                                                                      |  |
  762. | |    Path for Help Files:                                              |  |
  763. | |    C:\INSIGHTX\                                                      |  |
  764. | |                                                                      |  |
  765. | |    Path for Source Code Files:                                       |  |
  766. | |    C:\SAMPLES\                                                       |  |
  767. | |                                                                      |  |
  768. | |    Extension for Output Source Files:                                |  |
  769. | |    SRC                                                               |  |
  770. | |                                                                      |  |
  771. | |    < Accept >                                      < Cancel >        |  |
  772. | |                                                                      |  |
  773. | +======================================================================+  |
  774. +===========================================================================+
  775.                                  2.3  Run Menu
  776.  
  777. The Run Menu (Figure 2.10) allows the user to start the processing of the xBase
  778. programs to be analyzed, using the currently defined options.  The Run Menu is
  779. accessed by pressing <Alt>-R (holding down the Alt key while pressing R) or by
  780. placing the mouse cursor over the word Run and clicking the left button.  You
  781. begin processing the file by pressing the highlighted letter (P), simply pressing
  782. <Enter>, or placing the mouse cursor over the selection and clicking the left
  783. mouse button.
  784.                                                                         
  785. +========================= Figure 2.10 Run Menu =======================+
  786. |                                                                      |
  787. |   File   Options   Run   Help                                        |
  788. |                  +-----------------+                                 |
  789. |                  | Process File(s) |                                 |
  790. |                  +-----------------+                                 |
  791. |                                                                      |
  792. |                                                                      |
  793. |                                                                      |
  794. +======================================================================+
  795.  
  796.  
  797.  
  798.                             2.3.1  Process File(s)
  799.  
  800. Selecting this menu item starts the processing of xBase programs.  To show the
  801. progress of the analysis, the program keeps a running count of the line number
  802. being processed as shown in Figure 2.11.  At the end of each routine, the program
  803. will perform (if requested) the local variable and keyword concordance.  While
  804. this is being done, the program displays the variables being processed as shown
  805. in Figure 2.12.  A similar process occurs at the end of the program if a global
  806. variable/keyword concordance has been requested.  After the analysis is
  807. completed, an alert box is displayed (Figure 2.13) that informs the user of the
  808. completion of the run.  Pressing <Enter> or clicking the <OK> button will return
  809. the user to the menu.
  810.  
  811. Command Line Option: /G
  812.  
  813. When the command option /G is input on the command line, the menu is bypassed,
  814. and processing begins immediately using the files and options specified on the
  815. command line.  When processing is completed, the program returns to the DOS
  816. prompt.  The main use of this option is to allow the building of a batch file to
  817. process several different programs at once.
  818.  
  819.  
  820. +=================  Figure 2.11  Line Count Display  =====================+
  821. |                                                                         |
  822. |             +----------------------------------------------+            |
  823. |             |                                              |            |
  824. |             |       Processing line number:  50            |            |
  825. |             |                                              |            |
  826. |             |                                              |            |
  827. |             |                                              |            |
  828. |             |                                              |            |
  829. |             |                                              |            |
  830. |             +----------------------------------------------+            |
  831. |                                                                         |
  832. +=========================================================================+
  833.  
  834.  
  835. +============  Figure 2.12  Variable Processing Display  =================+
  836. |                                                                         |
  837. |             +----------------------------------------------+            |
  838. |             |                                              |            |
  839. |             |       Processing line number:  183           |            |
  840. |             |                                              |            |
  841. |             |                                              |            |
  842. |             |                                              |            |
  843. |             |                                              |            |
  844. |   +---------+----------------------------------------------+--------+   |
  845. |   |                Printing Variable Cross-Reference                |   |
  846. |   |                      for Subroutine:   Main                     |   |
  847. |   |                                                                 |   |
  848. |   |                 lpix                                            |   |
  849. |   |                                                                 |   |
  850. |   |                                                                 |   |
  851. |   +-----------------------------------------------------------------+   |
  852. |                                                                         |
  853. +=========================================================================+
  854.  
  855.  
  856. +===============  Figure 2.13  Analysis Completion Screen ================+
  857. |                                                                         |
  858. |                                                                         |
  859. |              +---------------------------------------------+            |
  860. |              |  Processing Completed                       |            |
  861. |              |                                             |            |
  862. |              |                                             |            |
  863. |              |                                             |            |
  864. |              +---------------------------------------------+            |
  865. |              |                    < OK >                   |            |
  866. |              +---------------------------------------------+            |
  867. |                                                                         |
  868. |                                                                         |
  869. +=========================================================================+
  870.  
  871.  
  872.                                 2.4  Help Menu
  873.  
  874. The Help Menu (Figure 2.14) allows the user to access on-line help about the
  875. settings of Insight for xBase and about the function of the program.  The Help Menu
  876. is accessed by pressing <Alt>-H (holding down the Alt key while pressing H) or
  877. by placing the mouse cursor over the word Help and clicking the left button. 
  878. Once the menu is displayed, a selection may be made by pressing the highlighted
  879. letter, using the cursor keys to highlight the selection and pressing <Enter>,
  880. or placing the mouse cursor over the selection and clicking the left mouse
  881. button.  In Figure 2.14, the highlighted letter for each selection is shown in
  882. boldface type.
  883.                                                                         
  884. +======================== Figure 2.14 Help Menu =======================+
  885. |                                                                      |
  886. |   File   Options   Run   Help                                        |
  887. |                        +--------------------+                        |
  888. |                        | Index              |                        |
  889. |                        | About This Program |                        |
  890. |                        +--------------------+                        |
  891. |                                                                      |
  892. |                                                                      |
  893. +======================================================================+
  894.  
  895.  
  896.  
  897.                                  2.4.1  Index
  898.  
  899. When the Index option is selected, a list box showing the help topics (Figure
  900. 2.15) is displayed.  The user may then select a help topic by highlighting the
  901. topic and selecting the <OK> button, or return to the menu by selecting the
  902. <Cancel> button.  When a topic is selected, information about the topic is
  903. displayed in a window as shown in Figure 2.16.  Selecting the <OK> button from
  904. the help topic screen returns the user to the help index.
  905.                                  
  906.  
  907. +================  Figure 2.15  Help Index Box =========================+
  908. |            +---------------------------+                              |
  909. |            |  +-----------------+      |                              |
  910. |            |  | About Box       |      |                              |
  911. |            |  | Characters Per  ^      |                              |
  912. |            |  | File Menu       *      |                              |
  913. |            |  | File Path Def   #      |                              |
  914. |            |  | Help Index      #      |                              |
  915. |            |  | Help Menu       #      |                              |
  916. |            |  | Indented Source #      |                              |
  917. |            |  | Input File      #      |                              |
  918. |            |  | Keyword Concord #      |                              |
  919. |            |  | Lines Per Page  v      |                              |
  920. |            |  | MAK File        |      |                              |
  921. |            |  +-----------------+      |                              |
  922. |            |                           |                              |
  923. |            |    < OK >   < Cancel >    |                              |
  924. |            |                           |                              |
  925. |            +---------------------------+                              |
  926. |                                                                       |
  927. +=======================================================================+
  928.  
  929.  
  930.  
  931.                                                                              
  932. +==================  Figure 2.16  Help Window  ==============================+
  933. |                                                                            |
  934. | +------------------------------------------------------------------------+ |
  935. | | Characters Per Line:                                                   | |
  936. | | This option specifies how many characters will be printed before the   | |
  937. | | Insight for xBase breaks the program statement into two or more output | |
  938. | | lines.  The length specified will be the number of characters on a     | |
  939. | | line, including the line number, any indentations (see Spaces to       | |
  940. | | Indent), and the program statement.  The user may input a value of 0,  | |
  941. | | which will tell the program not to split the lines, or any integer     | |
  942. | | value greater than 50.  The actual line length to be used will depend  | |
  943. | | on the paper width and print font to be used to print the output file. | |
  944. | | For my own work, I use a value of 132 and a compressed (17 cpi) font   | |
  945. | | for printing.  For indented source output, lines are never split and   | |
  946. | | this value is ignored.                                                 | |
  947. | |                                                                        | |
  948. | |                                                                        | |
  949. | |                                                                        | |
  950. | +------------------------------------------------------------------------+ |
  951. | |                            < OK >                                      | |
  952. | +------------------------------------------------------------------------+ |
  953. |                                                                            |
  954. +============================================================================+
  955.  
  956.  
  957.  
  958.  
  959.                            2.4.2  About This Program
  960.     
  961. This option displays a window (like the help window in Figure 2.16) that contains
  962. a general description of the program.  Selecting the <OK> button returns the user
  963. to the main menu.
  964.  
  965.  
  966.                            2.4.3  Command Line Help
  967.  
  968. Command Line Option: /?
  969.  
  970. When this option is entered on the command line, the program prints out to the
  971. screen a listing of the command line options, including a brief description of
  972. each.
  973.  
  974.                                3.0  Enhancements
  975.  
  976.  
  977. Future versions of Insight for xBase may be developed and released to enhance the
  978. capabilities of the current program.  Below is a list of possible program
  979. enhancements for later versions.  Input from registered users will help determine
  980. the priority in which these get implemented.  Additional suggestions from users
  981. may also be included.  Enhanced versions of the program will be available to all
  982. registered users for about $10.  This covers the cost of postage and of new disks
  983. and manuals.
  984.  
  985. Possible enhancements:
  986.  
  987.   o   Output directed to screen.
  988.  
  989.   o   Tree structure showing subroutine calls.
  990.  
  991.  
  992.                    Appendix A:  Command Line Options Summary
  993.  
  994.  
  995. In the following text, the optional parameters that may be entered on the command
  996. line will be described.  Each option is preceded by a slash (/), is identified
  997. by a single letter option designator (shown in boldface type), and is immediately
  998. followed by the required input (shown in italics).  In addition to the
  999. description of the command, the default values for each option will be listed.
  1000.  
  1001. /Finput_file      This option specifies the xBase program source file to be
  1002.                   processed.  The user must enter the complete filename of the
  1003.                   program source or MAK file.  The user may optionally enter the
  1004.                   file path for the file, but if the path is omitted, the
  1005.                   current directory will be assumed.  Wildcard characters (* or
  1006.                   ?) are not permitted in the input file name.  Default: None.
  1007.  
  1008. /M                This option indicates that the file specified by the input
  1009.                   file option is actually a list of files to be processed.  For
  1010.                   each file in the list, the path must either be specified in
  1011.                   the MAK file, or the file must reside in the current
  1012.                   directory.  Default:  None.
  1013.  
  1014. /Ooutput          This option specifies the output file or device to be used for
  1015.                   the documentation output.  If a file is to be used, the user
  1016.                   must specify a complete file name (wildcards are not allowed),
  1017.                   optionally including the file path.  If the path is not
  1018.                   specified, the current directory is assumed.  If a print
  1019.                   device is to be used, the user must specify the device name
  1020.                   (i.e., LPT1, LPT2, COM1, etc.).  Default:  No output.
  1021.  
  1022. /Cconfig_file     This option specifies the name of a configuration file to be
  1023.                   read.  This file (defined in Appendix C) contains page format
  1024.                   and file processing options to be used in running Insight for
  1025.                   xBase.  Keeping these values in a configuration file
  1026.                   relieves the user from entering the information for each file
  1027.                   to be processed.  The user must enter the complete name of the
  1028.                   file (no wildcards), and if the path is not specified, the
  1029.                   directory containing the file is assumed to be the same one
  1030.                   which contains the Insight for xBase executable file (INSIGHTX.EXE).
  1031.                   Default:  None.
  1032.  
  1033. /N#               This option specifies the number of spaces (up to 10) to
  1034.                   indent command structures.  Default: 3.
  1035.  
  1036.  
  1037. /L###             This option specifies the number of characters to print on
  1038.                   each line.  Insight for xBase will break command lines at the end
  1039.                   of the number of characters specified in order to make the
  1040.                   output fit properly on the page.  If a value of 0 is entered,
  1041.                   then lines are not broken.  For indented source output files,
  1042.                   command lines are never broken and this option is ignored. 
  1043.                   Default:  80.
  1044.  
  1045. /P##              This option specifies the number of lines to be printed on
  1046.                   each page of the documentation output.  Default: 60.
  1047.  
  1048. /Hpage_header     This option specifies the page header (single line) to be
  1049.                   printed at the top of each page of the output report.  The
  1050.                   page header can be as long as the line length specified above,
  1051.                   and can contain any descriptive text the user wants to
  1052.                   include.  In addition, the user may include backslash (\)
  1053.                   operators in the text to have program-dependent data printed
  1054.                   in the header.  These operators take the form of \A, where "A"
  1055.                   is one of the following five descriptors:
  1056.  
  1057.                   D -   The date that the report was run.  This is pulled from
  1058.                         the system date function.
  1059.                   T -   The time that the run started.  This is pulled from the
  1060.                         system time function.
  1061.                   N -   The name of the file being processed.  This can be
  1062.                         useful when processing a MAK file, as the program will
  1063.                         use the names of the files being analyzed to show which
  1064.                         routines are part of which file.
  1065.                   S -   The current subroutine being processed.  This is taken
  1066.                         from the SUB or FUNCTION statement at the beginning of
  1067.                         each routine.
  1068.                   P -   The current page number.
  1069.  
  1070.                   When entering the page header data from the command line, an
  1071.                   underscore (_) must be used to indicate each space in the
  1072.                   header string.  This is required since the module which
  1073.                   processes the command line options looks for spaces to
  1074.                   separate the different options.  Each underscore will be
  1075.                   converted to a space prior to printing the page header. 
  1076.                   Default: None.
  1077.  
  1078. /Va               This option specifies the type of variable concordance(s) to
  1079.                   be printed.  The values of a are as follows:  L for local
  1080.                   concordance, G for global concordance, or B for both
  1081.                   concordances.  Default: None.
  1082.  
  1083.  
  1084. /Ka               This option specifies the type of keyword concordance(s) to be
  1085.                   printed.  The values of a are as follows:  L for local
  1086.                   concordance, G for global concordance, or B for both
  1087.                   concordances.  Default: None.
  1088.  
  1089. /B#               This option specifies the programming language used in the
  1090.                   source file.  This information is used to access a database of
  1091.                   keywords so that Insight for xBase can distinguish between
  1092.                   variables and keywords when generating the concordances.  The
  1093.                   values of # for supported versions of xBase are:  1 for
  1094.                   FoxPro, 2 for dBase IV, 3 for FoxBase+, or 4 for dBase III+.
  1095.                   Any other value entered is ignored, and no language is
  1096.                   assumed.  Default: 0 (no language).
  1097.  
  1098. /Sext             This option specifies that Insight for xBase should create
  1099.                   indented source files using ext as the output file extension. 
  1100.                   Default: SRC.
  1101.  
  1102. /G                This options tells Insight for xBase to run the analysis using the
  1103.                   information specified on the command line (without accessing
  1104.                   the menu), and return to DOS upon completion.  Default:  No
  1105.                   additional parameters.
  1106.  
  1107.                      Appendix B:  Use of Data Input Forms
  1108.  
  1109.  
  1110. Insight for xBase makes use of several user interface methods to make it easier to
  1111. move around the program and enter necessary data.  These methods are pull-down
  1112. menus, input boxes, edit fields, check boxes, list boxes, radio button option
  1113. choices, and command buttons.  In this section, techniques for using these
  1114. methods with either the keyboard or the mouse will be presented.
  1115.  
  1116. Pull-down Menus
  1117.  
  1118. Insight for xBase uses a pull-down menu for the main menu of the program.  The menu
  1119. appears as a bar across the top of the screen, and as the main menu options are
  1120. selected, the sub-menu drops down below the menu bar.  To access the main menu
  1121. options, the user may press the <Alt> key followed by one of the highlighted
  1122. letters on the menu bar (for example, Alt-F for the File Menu).  Once the main
  1123. menu has been activated, the user may move between main menu options using the
  1124. left and right cursor keys.  To select a sub-menu option using the keyboard, the
  1125. user may either press the highlighted letter of the menu option, or use the up
  1126. and down cursor keys to move the light bar to the option then pressing <Enter>.
  1127.  
  1128. To select a main menu choice using the mouse, the user places the mouse cursor
  1129. over the option name and clicks the left mouse button.  To select a sub-menu
  1130. option, the user again moves the mouse cursor over the option and clicks the left
  1131. mouse button.  Figure B.1 shows an example of the pull-down menus.
  1132.                                                                         
  1133. +======================= Figure B.1  Pull-Down Menu ===================+
  1134. |                                                                      |
  1135. |   File   Options   Run   Help                                        |
  1136. | +--------------------+                                               |
  1137. | | Input File         |                                               |
  1138. | | MAK File           |                                               |
  1139. | +--------------------+                                               |
  1140. | | Output             |                                               |
  1141. | | Indented Source    |                                               |
  1142. | +--------------------+                                               |
  1143. | | Read Configuration |                                               |
  1144. | | Save Configuration |                                               |
  1145. | +--------------------+                                               |
  1146. | | Exit               |                                               |
  1147. | +--------------------+                                               |
  1148. |                                                                      |
  1149. +======================================================================+
  1150.  
  1151. Input Boxes
  1152.  
  1153. An input box is used to get a single piece of information from the user.  Once
  1154. it has been activated by the program, the user enters the required data in the
  1155. input area, then presses <Enter> or clicks the mouse on the <OK> command button
  1156. to accept the entered information and continue the program.  Figure B.2 shows an
  1157. example of an input box.
  1158.  
  1159.  
  1160. +======================  Figure B.2  Input Box  ===========================+
  1161. |                                                                          |
  1162. |    +----------------------------------------------------------+          |
  1163. |    |                                                          |          |
  1164. |    |         Enter a file specification:                      |          |
  1165. |    |      +-----------------------------------+               |          |
  1166. |    |      |  *.*                              |               |          |
  1167. |    |      +-----------------------------------+               |          |
  1168. |    |                                                          |          |
  1169. |    |                 < OK >                                   |          |
  1170. |    |                                                          |          |
  1171. |    |                                                          |          |
  1172. |    +----------------------------------------------------------+          |
  1173. |                                                                          |
  1174. +==========================================================================+
  1175.  
  1176. Edit Fields
  1177.  
  1178. Edit fields are used in groups on an input screen to obtain multiple pieces of
  1179. information from the user, usually about a related subject (i.e., page format
  1180. options).  Each edit field is preceded by a data description and has a
  1181. highlighted area for actual data input.  The user may move between edit fields
  1182. using the <Tab> and <Shift><Tab> keys, or by clicking on the field with the
  1183. mouse.  In each edit field, the user enters the required information using the
  1184. keyboard.  In Insight for xBase, the screens which use edit fields will also have an
  1185. <Accept> and a <Cancel> command button.  These buttons are described below, and
  1186. are used to determine whether variables in the program are set to the newly
  1187. entered values (Accept), or reset to their previous values (Cancel).  Using
  1188. either of these buttons will terminate the particular input screen.  Figure B.3
  1189. shows an example of a screen with several edit fields.
  1190.  
  1191. +=================  Figure B.3  Edit Field Example =======================+
  1192. |                                                                         |
  1193. |  +=================== Page Layout Options ==========================+   |
  1194. |  |                                                                  |   |
  1195. |  |   Number of Spaces to Indent:     4                              |   |
  1196. |  |                                                                  |   |
  1197. |  |   Number of Characters Per Line:  132                            |   |
  1198. |  |                                                                  |   |
  1199. |  |   Number of Lines Per Page:       55                             |   |
  1200. |  |                                                                  |   |
  1201. |  |   Page Header String:                                            |   |
  1202. |  |   Date: \D   Time: \T   Filename: \N   Subroutine: \S   Page     |   |
  1203. |  |                                                                  |   |
  1204. |  |   < Accept >                                    < Cancel >       |   |
  1205. |  |                                                                  |   |
  1206. |  +==================================================================+   |
  1207. +=========================================================================+
  1208.  
  1209.  
  1210. Check Boxes
  1211.  
  1212. Check boxes are used on an input screen to indicate options that are either on
  1213. or off.  Each check box consists of a pair of square brackets, [], and a
  1214. description of the option.  If the option is on, an "X" appears in the box
  1215. between the brackets.  To toggle a check box using the keyboard, the user moves
  1216. the cursor to the check box using the <Tab> or <Shift><Tab> keys, then presses
  1217. the <Space> bar to toggle the option.  Using the mouse, the user toggles the
  1218. check box value by clicking the left mouse key with the mouse cursor placed over
  1219. the check box.  Like edit field input screens, command buttons will be used on
  1220. the screen with check boxes to process the options.  Figure B.4 shows examples
  1221. of check boxes and radio buttons (described below).
  1222.  
  1223. +=============  Figure B.4  Check Box and Radio Button Example ===========+
  1224. |                                                                         |
  1225. | +===================== File Processing Options =====================+   |
  1226. | |                                                                   |   |
  1227. | |  Local Concordances:            Global Concordances:              |   |
  1228. | |  [X] Variables                  [X] Variables                     |   |
  1229. | |  [ ] Keywords                   [ ] Keywords                      |   |
  1230. | |                                                                   |   |
  1231. | |  [ ] Process INCLUDE Files                                        |   |
  1232. | |                                                                   |   |
  1233. | |      Language to use for Keywords                                 |   |
  1234. | |  (*) None     ( ) PDS 7.1     ( ) QB 4.5     ( ) VB               |   |
  1235. | |                                                                   |   |
  1236. | |  < Accept >                                  < Cancel >           |   |
  1237. | |                                                                   |   |
  1238. | +===================================================================+   |
  1239. +=========================================================================+
  1240.  
  1241. List Boxes
  1242.  
  1243. A list box is used to allow the user to make a selection among a series of
  1244. choices, such as a file list.  To make a selection using the keyboard, the user
  1245. moves the cursor to the list area using the <Tab> keys, then uses the up and down
  1246. cursor and <Page Up> and <Page Down> keys to highlight the selection.  The user
  1247. may then press <Enter> to accept the selection.  Using the mouse, the user may
  1248. click on the selection in the list to highlight it, or may click on the scroll
  1249. bar (the shaded area to the right of the choices) to move through the list. 
  1250. Clicking on one of the arrows on the scroll bar moves the highlight bar one
  1251. selection at a time, while clicking on the shaded area above or below the solid
  1252. block moves the highlight bar one page of selections at a time.  Once the
  1253. selection is highlighted, the user clicks on the <OK> button to accept the
  1254. selection, or on the <Cancel> button to exit the list box without making a
  1255. selection.  Figure B.5 shows an example of a list box.
  1256.  
  1257.  
  1258. +================  Figure B.5  List Box Example ========================+
  1259. |            +---------------------------+                              |
  1260. |            |  +-----------------+      |                              |
  1261. |            |  | About Box       |      |                              |
  1262. |            |  | Characters Per  ^      |                              |
  1263. |            |  | File Menu       *      |                              |
  1264. |            |  | File Path Def   #      |                              |
  1265. |            |  | Help Index      #      |                              |
  1266. |            |  | Help Menu       #      |                              |
  1267. |            |  | Indented Source #      |                              |
  1268. |            |  | Input File      #      |                              |
  1269. |            |  | Keyword Concord #      |                              |
  1270. |            |  | Lines Per Page  v      |                              |
  1271. |            |  | MAK File        |      |                              |
  1272. |            |  +-----------------+      |                              |
  1273. |            |                           |                              |
  1274. |            |    < OK >   < Cancel >    |                              |
  1275. |            |                           |                              |
  1276. |            +---------------------------+                              |
  1277. |                                                                       |
  1278. +=======================================================================+
  1279.  
  1280. Radio Buttons
  1281.  
  1282. Radio buttons are used to allow the user to choose one of several available
  1283. choices.  Radio buttons consist of a pair of parentheses along with a description
  1284. of the choice.  The currently selected option has a diamond in the parentheses. 
  1285. To select a radio button using the keyboard, the user moves the cursor to the
  1286. radio button using the <Tab> or <Shift><Tab> keys, then presses the <Space> bar
  1287. to select the option.  Using the mouse, the user selects the radio button by
  1288. clicking the left mouse key with the mouse cursor placed over the radio button. 
  1289. Figure B.4 shows examples of check boxes and radio buttons.
  1290.  
  1291. Command Buttons
  1292.  
  1293. Command buttons are used to initiate an action in the program.  When used on an
  1294. input screen, they are most often used to either accept or cancel the input data
  1295. entered by the user.  Command buttons consist of a command word enclosed in angle
  1296. brackets, <>.  To select a command button with the keyboard, the user must use
  1297. the <Tab> keys to move the cursor to the command button.  The user then presses
  1298. <Enter> to execute the command.  With the mouse, the user just moves the mouse
  1299. cursor to the command button and clicks the left mouse button.  <Accept> and
  1300. <Cancel> command buttons are shown in Figures B.3 and B.4.
  1301.  
  1302.                         Appendix C:  Configuration File
  1303.  
  1304. A configuration file is a text file which contains the values of several program
  1305. configuration options.  The file can be created with any editor which produces
  1306. ASCII text files.  The keywords of the file and the values of the parameters are
  1307. read in as text strings and must be enclosed in double quotes (").  Each keyword
  1308. and value combination occupies one line of the file.  The keywords and their
  1309. possible values are listed below.  An example of a configuration file is shown
  1310. in Figure C.1.
  1311.  
  1312.       Keyword           Description and Value
  1313.       LOCVAR            Local variable concordance desired.  Value - 1.
  1314.       GBLVAR            Global variable concordance desired.  Value - 1.
  1315.       LOCKEY            Local keyword concordance desired.  Value - 1.
  1316.       GBLKEY            Global keyword concordance desired.  Value - 1.
  1317.       DEFLNG            Default language to use.  Value - 1, 2, or 3 as
  1318.                         described in Section 2.2.2.4.
  1319.       INDENT            The number of spaces to indent structures.  Value - 1
  1320.                         through 10.
  1321.       LINLEN            The number of character to print per line.  Value - 0,
  1322.                         or any positive integer over 50.
  1323.       PAGLNG            The number of lines to print per page.  Value - any
  1324.                         positive integer over 10.
  1325.       HEADER            The one-line header to be printed at the top of each
  1326.                         page.  Value - header string as defined in Section
  1327.                         2.2.1.4.
  1328.  
  1329. +===============  Figure C.1  Sample Configuration File =============================+
  1330. |                                                                                    |
  1331. | "LOCVAR"   "1"                                                                     |
  1332. | "GBLVAR"   "1"                                                                     |
  1333. | "DEFLNG"   " 1"                                                                    |
  1334. | "INDENT"   " 4"                                                                    |
  1335. | "LINLEN"   " 132"                                                                  |
  1336. | "PAGLNG"   " 55"                                                                   |
  1337. | "HEADER"   "Date: \D  Time: \T   Filename: \N    Subroutine: \S     Page No: \P"   |
  1338. +====================================================================================+
  1339.  
  1340.                        Appendix D:  Sample Program File
  1341.  
  1342. @ 1,1 GET I
  1343. * Do case example
  1344. DO CASE
  1345. CASE I=1
  1346. @ 2,1 SAY "I="+STR(I,5)
  1347. CASE I=2
  1348. @ 2,1 SAY "I="+STR(-I,5)
  1349. CASE I=3
  1350. @ 2,1 SAY "I=0"
  1351. ENDCASE
  1352. 'If example
  1353. IF I > 2
  1354. @ 4,1 SAY "Yes"
  1355. ELSE
  1356. @ 4,1 SAY "No"
  1357. ENDIF
  1358. 'Do loop example
  1359. J = 1
  1360. DO WHILE J <= 5
  1361. @ 6,1 SAY J
  1362. J = J + 1
  1363. ENDDO
  1364. 'For example
  1365. FOR J = 1 TO 10
  1366. @ 8,1 SAY -J
  1367. ENDFOR
  1368. DO ENDPROG
  1369. RETURN
  1370.  
  1371. PROCEDURE ENDPROG
  1372. J = 5 * 5
  1373. I = 5 ^ .33
  1374. @ 10,1 SAY "Five Squared is: "+STR(J,5)
  1375. @ 11,1 SAY "Cube root of twenty-five is: "+STR(I,5)
  1376. @ 12,1 SAY "End of Program"
  1377. RETURN
  1378.  
  1379.  
  1380.  
  1381.  
  1382.                    Appendix E:  Sample Documentation Output
  1383.  
  1384. The next several pages show the output resulting from the processing of the
  1385. sample program shown in Appendix D.
  1386.  
  1387.  
  1388. Date: 10-02-1992  Time: 11:24:59   Filename: D:\BASDOC\SAMPLE.PRG    Procedure: SAMPLE     Page No:   1
  1389.  
  1390.  
  1391.      1   @ 1,1 GET I 
  1392.      2   * Do case example 
  1393.      3   DO CASE 
  1394.      4        CASE I=1 
  1395.      5        1    @ 2,1 SAY "I="+STR(I,5) 
  1396.      6        CASE I=2 
  1397.      7        2    @ 2,1 SAY "I="+STR(-I,5) 
  1398.      8        CASE I=3 
  1399.      9        3    @ 2,1 SAY "I=0" 
  1400.     10   ENDCASE 
  1401. Mismatched single quotation marks in line    11
  1402.     11   'If example 
  1403.     12   IF I > 2 
  1404.     13   T    @ 4,1 SAY "Yes" 
  1405.     14   ELSE 
  1406.     15   F    @ 4,1 SAY "No" 
  1407.     16   ENDIF 
  1408. Mismatched single quotation marks in line    17
  1409.     17   'Do loop example 
  1410.     18   J = 1 
  1411.     19   DO WHILE J <= 5 
  1412.     20   W    @ 6,1 SAY J 
  1413.     21   W    J = J + 1 
  1414.     22   ENDDO 
  1415. Mismatched single quotation marks in line    23
  1416.     23   'For example 
  1417.     24   FOR J = 1 TO 10 
  1418.     25   N    @ 8,1 SAY -J 
  1419.     26   ENDFOR 
  1420.     27   DO ENDPROG 
  1421.     28   RETURN 
  1422.  
  1423. Local Variable Cross Reference for Subroutine: SAMPLE
  1424.  
  1425.  
  1426. example                  11     17     23
  1427. I                         1      4      5      6      7      8     12
  1428. J                        18     19     20     21     21     24     25
  1429.  
  1430.  
  1431. Date: 10-02-1992  Time: 11:24:59   Filename: D:\BASDOC\SAMPLE.PRG    Procedure: ENDPROG     Page No:   2
  1432.  
  1433.  
  1434.      1   PROCEDURE ENDPROG 
  1435.      2   J = 5 * 5 
  1436.      3   I = 5 ^ .33 
  1437.      4   @ 10,1 SAY "Five Squared is: "+STR(J,5) 
  1438.      5   @ 11,1 SAY "Cube root of twenty-five is: "+STR(I,5) 
  1439.      6   @ 12,1 SAY "End of Program" 
  1440.      7   RETURN 
  1441.  
  1442. Local Variable Cross Reference for Subroutine: ENDPROG
  1443.  
  1444.  
  1445. I                         3      5
  1446. J                         2      4
  1447.  
  1448.  
  1449. Date: 10-02-1992  Time: 11:24:59   Filename: D:\BASDOC\SAMPLE.PRG    Procedure:      Page No:   3
  1450.  
  1451.  
  1452.  
  1453.  
  1454.  
  1455. Date: 10-02-1992  Time: 11:24:59   Filename: D:\BASDOC\SAMPLE.PRG    Procedure:      Page No:   4
  1456.  
  1457.  
  1458.  
  1459. Global Variable Cross Reference
  1460.  
  1461. example               SAMPLE              
  1462. I                     SAMPLE                ENDPROG             
  1463. J                     SAMPLE                ENDPROG             
  1464.  
  1465.  
  1466. Date: 10-02-1992  Time: 11:24:59   Filename: D:\BASDOC\SAMPLE.PRG    Procedure:      Page No:   5
  1467.  
  1468.  
  1469.  
  1470. Table of Contents
  1471.  
  1472.   Subroutine                 File                          Page
  1473. ENDPROG                      D:\BASDOC\SAMPLE.PRG           2 
  1474. SAMPLE                       D:\BASDOC\SAMPLE.PRG           1 
  1475.  
  1476.  
  1477.                    Appendix F:  Sample Indented Source File
  1478. @ 1,1 GET I
  1479. * Do case example 
  1480. DO CASE 
  1481.     CASE I=1 
  1482.         @ 2,1 SAY "I="+STR(I,5) 
  1483.     CASE I=2 
  1484.         @ 2,1 SAY "I="+STR(-I,5) 
  1485.     CASE I=3 
  1486.         @ 2,1 SAY "I=0" 
  1487. ENDCASE 
  1488. 'If example 
  1489. IF I > 2 
  1490.     @ 4,1 SAY "Yes" 
  1491. ELSE 
  1492.     @ 4,1 SAY "No" 
  1493. ENDIF 
  1494. 'Do loop example 
  1495. J = 1 
  1496. DO WHILE J <= 5 
  1497.     @ 6,1 SAY J 
  1498.     J = J + 1 
  1499. ENDDO 
  1500. 'For example 
  1501. FOR J = 1 TO 10 
  1502.     @ 8,1 SAY -J 
  1503. ENDFOR 
  1504. DO ENDPROG 
  1505. RETURN 
  1506. PROCEDURE ENDPROG 
  1507. J = 5 * 5 
  1508. I = 5 ^ .33 
  1509. @ 10,1 SAY "Five Squared is: "+STR(J,5) 
  1510. @ 11,1 SAY "Cube root of twenty-five is: "+STR(I,5) 
  1511. @ 12,1 SAY "End of Program" 
  1512. RETURN 
  1513.  
  1514.